﻿using System;
using System.Collections.Generic;
using System.Globalization;
using System.Threading;

namespace Dot5Demo
{
    /*
    https://docs.microsoft.com/zh-cn/dotnet/core/extensions/localization
    https://docs.microsoft.com/zh-cn/dotnet/core/extensions/globalization
    https://docs.microsoft.com/zh-cn/dotnet/core/extensions/create-resource-files
     */

    public class Config
    {
        public static Config Default
        {
            get
            {
                var Config = new Config()
                {
                    Language = "zh-CN",
                    Params = new Dictionary<string, int>(),
                };
                for (int i = 0; i < 26; i++)
                {
                    Config.Params.Add("A" + i, Environment.TickCount);
                    Thread.Sleep(7);
                }
                return Config;
            }
        }
        public Dictionary<string, int> Params { get; set; }
        public string Language { get; set; }

        public static CultureInfo[] GetAllLanguages()
        {
            return new CultureInfo[]
            {
                new CultureInfo("zh-CN"),
                new CultureInfo("en-US"),
            };
        }
    }
}